<template>
	<view class="mall-order-detail-bar">
		<view @click="cancel" class="btn b1" v-if="order.orderStatus==0">
			取消订单
		</view>
		<view @click="pay" class="btn b2" v-if="order.paid==0&&order.orderStatus==0">
			继续支付
		</view>
		<view @click="bill" class="btn b1" v-if="order.paid==1">
			申请开票
		</view>
	</view>
</template>

<script>
	export default {
		props:{
			order:Object
		},
		methods:{
				cancel(){
					this.$emit("cancel")
				},
				pay(){
					this.$emit("pay")
				},
				bill(){
					this.$Router.push({
						path:"/pages/bill/bill",
						query:{
							orderNo:this.order.orderNo,
							amount:this.order.pay
						}
					})
				}
		},
		data() {
			return {
				
			};
		}
	}
</script>

<style lang="stylus">
	.mall-order-detail-bar
		height 88upx
		background-color white
		display flex
		align-items center
		justify-content flex-end
		padding 0 21upx
		.btn
			width:130upx;
			height:52upx;
			border:1px solid rgba(111,111,111,1);
			border-radius:26upx;
			font-size 24upx
			display flex
			align-items center
			justify-content center
			margin-left 20upx
			&.b1
				border:1px solid rgba(111,111,111,1);
				color #6F6F6F
			&.b2
				color #F7895E
				border:1px solid rgba(247,137,94,1);
</style>
